correctness proof